<%@page import="online_store.model.bus.CategoryBus"%>
<%@page import="online_store.utils.ApplicationContextProvider"%>
<%@page import="online_store.model.dto.CategoryDTO"%>
<%@page import="java.util.List"%>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>

<%
	List<CategoryDTO> category_list = ApplicationContextProvider.getApplicationContext().getBean(CategoryBus.class).findAll();
%>

	<div class="left_content">
      <div class="title_box">Categories</div>
      <ul class="left_menu">
      
      	<%
      		for(int i = 0; i < category_list.size(); i++){
      	%>
      		<li class='<%= i % 2 == 0 ? "even" : "odd"%>'>
      			<a href="http://all-free-download.com/free-website-templates/"><%= category_list.get(i).getName()%></a>
      		</li>
      	<%	
      		}
      	%>
      </ul>
      <div class="title_box">Special Products</div>
      <div class="border_box">
        <div class="product_title"><a href="details.html">Motorola 156 MX-VL</a></div>
        <div class="product_img"><a href="details.html"><img src="images/laptop.png" alt="" border="0" /></a></div>
        <div class="prod_price"><span class="reduce">350$</span> <span class="price">270$</span></div>
      </div>
      <div class="title_box">Newsletter</div>
      <div class="border_box">
        <input type="text" name="newsletter" class="newsletter_input" value="your email"/>
        <a href="http://all-free-download.com/free-website-templates/" class="join">join</a> </div>
      <div class="banner_adds"> <a href="http://all-free-download.com/free-website-templates/"><img src="images/bann2.jpg" alt="" border="0" /></a> </div>
    </div>
    <!-- end of left content -->

</body>
</html>